#include "HexapodPoint3d.h"

Point3D opPoint3dSub(const Point3D* lhs, const Point3D* rhs) {
	Point3D pt3d = {lhs->x - rhs->x, lhs->y - rhs->y, lhs->z - rhs->z};
	return pt3d;
};

Point3D opPoint3dMul(const Point3D* lhs, const float coef) {
	Point3D pt3d = {lhs->x * coef, lhs->y * coef, lhs->z * coef};
	return pt3d;
};

Point3D opPoint3dPlus(const Point3D* lhs, const Point3D* rhs) {
	Point3D pt3d = {lhs->x + rhs->x, lhs->y + rhs->y, lhs->z + rhs->z};
	return pt3d;
};

bool opPoint3dEqual(const Point3D* lhs, const Point3D* rhs) {
	bool rnt = false;
	rnt = (lhs->x == rhs->x) && (lhs->y == rhs->y) && (lhs->z == rhs->z);
	return rnt;
};